package net.itren.jetpackdemo.utils.network

import okhttp3.MediaType
import java.io.File

class FileWrapper(file: File, fileName: String, contentType: MediaType?) {

    var file: File
    var fileName: String
    var contentType: MediaType?
    var fileSize: Long

    init {
        this.file = file
        this.fileName = fileName
        this.contentType = contentType

        this.fileName ?: "nofilename"


        fileSize = file.length()
    }


    override fun toString(): String {
        return "FileWrapper{file=$file, fileName='$fileName, contentType=$contentType, fileSize=$fileSize}"
    }

    init {
        fileSize = file.length()
    }
}